package com.pazl.check.api.req.dto;

import java.io.Serializable;
import java.util.List;

import javax.validation.Valid;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

import org.hibernate.validator.group.GroupSequenceProvider;

import com.pazl.check.api.dto.BaseFileDto;
import com.pazl.check.api.dto.CarInfoDto;
import com.pazl.check.api.dto.DealerInfoDto;
import com.pazl.check.api.dto.FinanceBaseInfoDto;
import com.pazl.check.api.dto.RenterInfoDto;
import com.pazl.check.api.dto.RenterZXUrlDto;
import com.pazl.check.api.dto.SponsorInfoDto;
import com.pazl.check.api.dto.UserInfoDto;
import com.pazl.check.api.provider.Req25GroupSequenceProvider;


/**
 * 2.5接口请求入参
 * @author chenyn
 *
 * 2020年5月11日
 */
@GroupSequenceProvider(Req25GroupSequenceProvider.class)
public class Req25Dto implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = -2594640313469714180L;
	
	/**
	 * 请求代码
	 */
	@NotEmpty(message ="requestCode missing.")
	@Pattern(regexp="4117",message="requestCode error. only【4117】")
	private String requestCode;
	
	/**
	 * 请求类型
	 */
	@NotEmpty(message ="requestType missing.")
	@Pattern(regexp="ADD_PREINFO_SUBMIT",message="requestType error. only 【ADD_PREINFO_SUBMIT】")
	private String requestType;
	
	/**
	 * 用户信息
	 */
	@Valid
	@NotNull(message="userInfo missing.")
	private UserInfoDto userInfo;
	
	/**
	 * 车辆信息
	 */
	@Valid
	@NotNull(message="carInfo missing.")
	private List<CarInfoDto> carInfo;
	
	/**
	 * 融资信息
	 */
	@Valid
	@NotNull(message="financeBaseInfo missing.")
	private FinanceBaseInfoDto financeBaseInfo;
	
	/**
	 * 承租人信息
	 */
	@Valid
	@NotNull(message="renterInfo missing.")
	private RenterInfoDto renterInfo;
	
	/**
	 * 担保人信息
	 */
	//@Valid
	@NotNull(message="sponsorInfos missing.",groups = {Sponsor.class})
	private List<@Valid SponsorInfoDto> sponsorInfos;
	
	/**
	 * 承租人相关文件
	 */
	@Valid
	@NotNull(message="rentUrlList missing.")
	private List<BaseFileDto> rentUrlList;
	
	/**
	 * 担保人相关文件
	 */
	private List<List<BaseFileDto>> sponsorUrlList;
	
	/**
	 * 经销商信息
	 */
	@Valid
	@NotNull(message="dealerInfo missing.")
	private DealerInfoDto dealerInfo;
	
	/**
	 * 征信信息
	 */
	@Valid
	@NotNull(message="renterZXUrl missing.")
	private List<RenterZXUrlDto> renterZXUrl;
	
	
	public String getRequestCode() {
		return requestCode;
	}
	public void setRequestCode(String requestCode) {
		this.requestCode = requestCode;
	}
	public String getRequestType() {
		return requestType;
	}
	public void setRequestType(String requestType) {
		this.requestType = requestType;
	}
	public UserInfoDto getUserInfo() {
		return userInfo;
	}
	public void setUserInfo(UserInfoDto userInfo) {
		this.userInfo = userInfo;
	}
	public List<CarInfoDto> getCarInfo() {
		return carInfo;
	}
	public void setCarInfo(List<CarInfoDto> carInfo) {
		this.carInfo = carInfo;
	}
	public FinanceBaseInfoDto getFinanceBaseInfo() {
		return financeBaseInfo;
	}
	public void setFinanceBaseInfo(FinanceBaseInfoDto financeBaseInfo) {
		this.financeBaseInfo = financeBaseInfo;
	}
	public RenterInfoDto getRenterInfo() {
		return renterInfo;
	}
	public void setRenterInfo(RenterInfoDto renterInfo) {
		this.renterInfo = renterInfo;
	}
	public List<SponsorInfoDto> getSponsorInfos() {
		return sponsorInfos;
	}
	public void setSponsorInfos(List<SponsorInfoDto> sponsorInfos) {
		this.sponsorInfos = sponsorInfos;
	}
	public List<BaseFileDto> getRentUrlList() {
		return rentUrlList;
	}
	public void setRentUrlList(List<BaseFileDto> rentUrlList) {
		this.rentUrlList = rentUrlList;
	}
	public List<List<BaseFileDto>> getSponsorUrlList() {
		return sponsorUrlList;
	}
	public void setSponsorUrlList(List<List<BaseFileDto>> sponsorUrlList) {
		this.sponsorUrlList = sponsorUrlList;
	}
	public DealerInfoDto getDealerInfo() {
		return dealerInfo;
	}
	public void setDealerInfo(DealerInfoDto dealerInfo) {
		this.dealerInfo = dealerInfo;
	}
	public List<RenterZXUrlDto> getRenterZXUrl() {
		return renterZXUrl;
	}
	public void setRenterZXUrl(List<RenterZXUrlDto> renterZXUrl) {
		this.renterZXUrl = renterZXUrl;
	}
	
	public interface Sponsor{
		
	}
}
